package com.wyh.lotterysystem.service.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

@AllArgsConstructor
@Getter
public enum ActivityPrizeStatusEnum {
    INIT(1,"未被抽取"),
    COMPLETED(2,"已被抽取");

    private final Integer code;
    private final String msg;

    public static ActivityPrizeStatusEnum forName(String name){
        for (ActivityPrizeStatusEnum activityStatusEnum : ActivityPrizeStatusEnum.values()){
            if (name.equalsIgnoreCase(activityStatusEnum.name())){
                return activityStatusEnum;
            }
        }
        return null;
    }
}
